#define _CRT_SECURE_NO_WARNINGS 
#include<iostream>
using namespace std;

class A {
public:
	virtual ~A() { cout << "A"; }
};
class B : public A {
public:
	~B() { cout << "B"; }
};
int main() {
	A* ptr = new B();
	delete ptr;
	return 0;
}